package com.zhilianbao.leyaogo.model.response.shoppingcart;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * Author: hcy
 * Description:
 * Created: 2016/11/17 15:29
 */
public class GoodsSKU implements Parcelable{
    private long goodsSkuId;//主键 SKU ID ,
    private long goodsId;//对应商品编号 ,
    private String goodsSn;//SKU商品编码 店铺唯一 ,
    private String goodsSkuName;// 商品SKU名称 ,
    private String goodsSkuFullName;//商品SKU全名称 ,
    private String itemIds;//对应item编号 逗号隔开 ,
    private String itemVals;//对应item值 逗号隔开 ,
    private double getmPrice;//市场价 ,
    private double price;//销售价 ,
    private int saleNumber;//销售数量 ,
    private int stockNumber;//库存数量 3 SKU独立库存 设置 ,
    private int statusCode;//状态 0 下架 1 上架 ,
    private int deleteFlag;//删除状态 0 正常 1 删除 ,
    private int stockStatus;//(integer, optional): 库存状态 0库存充足 1库存不足 2库存紧张 ,
    private String comments;//备注

    protected GoodsSKU(Parcel in) {
        goodsSkuId = in.readLong();
        goodsId = in.readLong();
        goodsSn = in.readString();
        goodsSkuName = in.readString();
        goodsSkuFullName = in.readString();
        itemIds = in.readString();
        itemVals = in.readString();
        getmPrice = in.readDouble();
        price = in.readDouble();
        saleNumber = in.readInt();
        stockNumber = in.readInt();
        statusCode = in.readInt();
        deleteFlag = in.readInt();
        stockStatus = in.readInt();
        comments = in.readString();
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeLong(goodsSkuId);
        dest.writeLong(goodsId);
        dest.writeString(goodsSn);
        dest.writeString(goodsSkuName);
        dest.writeString(goodsSkuFullName);
        dest.writeString(itemIds);
        dest.writeString(itemVals);
        dest.writeDouble(getmPrice);
        dest.writeDouble(price);
        dest.writeInt(saleNumber);
        dest.writeInt(stockNumber);
        dest.writeInt(statusCode);
        dest.writeInt(deleteFlag);
        dest.writeInt(stockStatus);
        dest.writeString(comments);
    }

    @Override
    public int describeContents() {
        return 0;
    }

    public static final Creator<GoodsSKU> CREATOR = new Creator<GoodsSKU>() {
        @Override
        public GoodsSKU createFromParcel(Parcel in) {
            return new GoodsSKU(in);
        }

        @Override
        public GoodsSKU[] newArray(int size) {
            return new GoodsSKU[size];
        }
    };

    public long getGoodsSkuId() {
        return goodsSkuId;
    }

    public void setGoodsSkuId(long goodsSkuId) {
        this.goodsSkuId = goodsSkuId;
    }

    public long getGoodsId() {
        return goodsId;
    }

    public void setGoodsId(long goodsId) {
        this.goodsId = goodsId;
    }

    public String getGoodsSn() {
        return goodsSn;
    }

    public void setGoodsSn(String goodsSn) {
        this.goodsSn = goodsSn;
    }

    public String getGoodsSkuName() {
        return goodsSkuName;
    }

    public void setGoodsSkuName(String goodsSkuName) {
        this.goodsSkuName = goodsSkuName;
    }

    public String getGoodsSkuFullName() {
        return goodsSkuFullName;
    }

    public void setGoodsSkuFullName(String goodsSkuFullName) {
        this.goodsSkuFullName = goodsSkuFullName;
    }

    public String getItemIds() {
        return itemIds;
    }

    public void setItemIds(String itemIds) {
        this.itemIds = itemIds;
    }

    public String getItemVals() {
        return itemVals;
    }

    public void setItemVals(String itemVals) {
        this.itemVals = itemVals;
    }

    public double getGetmPrice() {
        return getmPrice;
    }

    public void setGetmPrice(double getmPrice) {
        this.getmPrice = getmPrice;
    }

    public double getPrice() {
        return price;
    }

    public void setPrice(double price) {
        this.price = price;
    }

    public int getSaleNumber() {
        return saleNumber;
    }

    public void setSaleNumber(int saleNumber) {
        this.saleNumber = saleNumber;
    }

    public int getStockNumber() {
        return stockNumber;
    }

    public void setStockNumber(int stockNumber) {
        this.stockNumber = stockNumber;
    }

    public int getStatusCode() {
        return statusCode;
    }

    public void setStatusCode(int statusCode) {
        this.statusCode = statusCode;
    }

    public int getDeleteFlag() {
        return deleteFlag;
    }

    public void setDeleteFlag(int deleteFlag) {
        this.deleteFlag = deleteFlag;
    }

    public int getStockStatus() {
        return stockStatus;
    }

    public void setStockStatus(int stockStatus) {
        this.stockStatus = stockStatus;
    }

    public String getComments() {
        return comments;
    }

    public void setComments(String comments) {
        this.comments = comments;
    }
}
